Skip to content

feat(ad): verify NTAuth CA certificate paths against published roots - #2812

Open
FiraSenax wants to merge 105 commits into
maester365:mainfrom
FiraSenax:codex/ntauth-certificate-chain
Open

FiraSenax wants to merge 105 commits into
maester365:mainfrom
FiraSenax:codex/ntauth-certificate-chain

Conversation

@FiraSenax

@FiraSenax FiraSenax commented Nov 14, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Adds AD-PKI-13, an informational native check that verifies CA certificate paths from the forest's NTAuth store to roots published in Active Directory. It handles Microsoft and third-party CA certificates without requiring an enterprise CA registration.

Dependency and review

Depends on #2734. Its integration repairs are offered in soulemike/maester#13, targeting the author's consolidation branch. Current upstream main (2d659e85) and the repair ancestry are included here; this PR now merges without conflicts.

Review the five-file NTAuth increment. Merge #2734 first, including its accepted repairs, then rebase this follow-up onto main. The main-based diff continues to include the consolidation until that dependency lands. Its 90 retired AD IDs originate in #2734; this extension adds AD-PKI-13.

Behavior

  • Reuses the cached AD configuration inventory and the shared public-certificate parser. The generic LDAP byte-array projection repair now lives in the consolidation repair; this extension adds optional public DER output for path construction.
  • Builds offline .NET chains with CustomRootTrust, published roots as explicit anchors, and published intermediate, enterprise CA and NTAuth certificates as possible issuers. Certificates supplied only by the runner's OS cache cannot make a path verify.
  • Checks signatures, validity, CA constraints and certificate-signing key usage. Includes the non-self-issued NTAuth CA when enforcing issuer path-length limits. Deduplicates by SHA-256 certificate identifier.
  • Reports Passed for verified published paths, Investigate for unverifiable paths, NotApplicable for an observed empty NTAuth store, and Error for unavailable or malformed evidence. The empty-store explanation remains visible, with an explicit return.
  • Escapes certificate-controlled HTML and Markdown in result tables.

Classification and limits

Product=ad, Feature=certificate-services, Area=authentication, ResourceType=CertificateAuthority, Info / Preview, Mitre=None, Control=nist-800-53-r5:SC-17. It supports the certificate-path portion of SC-17 and does not affect scores.

No AIA downloads, revocation requests, private-key operations, enrollment or PKINIT are performed. It does not establish organizational root approval, effective DC trust, smart-card/client-auth EKU suitability, certificate mappings, enrollment authorization, template security or the CA's issuance policy. NTAuth authorization and root trust remain separate inputs.

Validation

  • Analyzer follow-up at 39cb38919 (18 November 2026): scope a justified PSUseShouldProcessForStateChangingFunctions suppression to New-PathTestCertificate, which creates in-memory test fixtures without changing external state. The explicit rule reports one finding before the annotation and none afterward; default ScriptAnalyzer also reports no findings for the file. All 80 certificate/native-engine cases and Build-LocalMaester.ps1 passed again. Production helpers and the native check are unchanged.
  • 80 final certificate/native-engine cases passed: 55 NTAuth path/native-engine cases and 25 shared certificate-inventory cases. Certificate parsing, signatures and chain validation are real; directory reads are mocked.
  • Includes all 20 combinations of one through four subordinate CAs and root path-length constraints 0 through 4, observed empty-store output, single/multiple LDAP-projected DER values across all four inventory roles, malformed/mixed evidence, unpublished issuers and blocked certificate downloads.
  • Three test-builder checks passed on the final tree. The 13 Golden selection/config/legacy-tag cases passed after reconciliation with main.
  • Module build and built-output validation passed; AD-PKI-13 remains valid, Info / Preview, with no metadata errors.
  • The repair base passed 1,857 focused metadata/lint, ScriptAnalyzer, parameter, framework, changed-check and builder cases, plus its expanded 25-case certificate inventory suite. Full-suite and isolated-control results are documented in the repair PR; no entirely green full-suite run is claimed.
  • The four NTAuth-specific helper/check/guide files remain byte-identical to cd264a6a3; the certificate test file additionally carries the scoped analyzer suppression above. At cd264a6a3, 34/34 Windows Server 2025 AD/LDAPS scenarios matched, including all root/depth combinations and multi-valued certificate projection. Those scenarios used the native engine, fresh processes, validated LDAPS and no enterprise CA registrations. No new live-AD run was performed for these integration and analyzer changes.

Sources: NTAuth publication, third-party CA authentication prerequisites, .NET chain policy.

Ready for incremental review. #2734 retains its own draft/live-validation and AD-FOR-03 review requirements; the documented dependency and merge order still apply.

@coderabbitai

coderabbitai Bot commented Nov 14, 2026 •

Copy link
Copy Markdown
Contributor

Important

Review skipped

Too many files!

This PR contains 568 files, which is 418 over the limit of 150.

To get a review, reduce the PR to 150 files or fewer by splitting it into smaller PRs or changing its base branch.

Upgrade to a paid plan to raise the limit.

Usage-priced reviews support at most 300 files.

Run configuration

Commits

Reviewing files that changed from the base of the PR and between 2d659e8 and 39cb389.

Files selected for processing: 568

  • build/golden/Export-MtLegacyTagTable.ps1
  • build/golden/native-test-replacements.psd1
  • powershell/assets/Maester.LegacyTags.json
  • powershell/internal/checks/ad/ad/Assert-MtAdUserAccountControl.ps1
  • powershell/internal/checks/ad/ad/ConvertTo-MtAdConfigurationInventoryCell.ps1
  • powershell/internal/checks/ad/ad/Format-MtAdSiteInventoryValue.ps1
  • powershell/internal/checks/ad/ad/Format-MtAdSummaryTable.ps1
  • powershell/internal/checks/ad/ad/Format-MtAdUserSecurityTable.ps1
  • powershell/internal/checks/ad/ad/Get-MtAdCertificateInventory.ps1
  • powershell/internal/checks/ad/ad/Get-MtAdConfigurationInventory.ps1
  • powershell/internal/checks/ad/ad/Get-MtAdConfigurationInventorySiteLinkTransport.ps1
  • powershell/internal/checks/ad/ad/Get-MtAdDomainControllerRelease.ps1
  • powershell/internal/checks/ad/ad/Get-MtAdDomainControllersInScope.ps1
  • powershell/internal/checks/ad/ad/Get-MtAdDomainNameFindings.ps1
  • powershell/internal/checks/ad/ad/Get-MtAdFsmoPlacement.ps1
  • powershell/internal/checks/ad/ad/Get-MtAdFunctionalLevelAssessment.ps1
  • powershell/internal/checks/ad/ad/Get-MtAdOrganizationalUnitOverview.ps1
  • powershell/internal/checks/ad/ad/Get-MtAdPasswordPolicyUsage.ps1
  • powershell/internal/checks/ad/ad/Get-MtAdSiteSubnetOverview.ps1
  • powershell/internal/checks/ad/ad/Get-MtAdStateCollection.ps1
  • powershell/internal/checks/ad/ad/Get-MtAdSubnetInventory.ps1
  • powershell/internal/checks/ad/ad/Get-MtAdUserPathFindings.ps1
  • powershell/internal/checks/ad/ad/Invoke-MtAdConfigurationInventoryReport.ps1
  • powershell/internal/checks/ad/ad/Test-MtAdPasswordPolicyConfiguration.ps1
  • powershell/internal/checks/ad/ad/Test-MtAdUserOrdinaryIdentity.ps1
  • powershell/internal/services/ad/Get-MtAdNtAuthCertificatePath.ps1
  • powershell/internal/services/ad/Test-MtAdDomainControllerAccount.ps1
  • powershell/internal/services/ad/protocol/ConvertFrom-MtLdapValue.ps1
  • powershell/internal/services/ad/queries/Get-MtLdapComputer.ps1
  • powershell/internal/services/ad/queries/Get-MtLdapConfigurationContainer.ps1
  • powershell/internal/services/ad/queries/Get-MtLdapDomain.ps1
  • powershell/internal/services/ad/queries/Get-MtLdapDomainController.ps1
  • powershell/internal/services/ad/queries/Get-MtLdapFineGrainedPasswordPolicy.ps1
  • powershell/internal/services/ad/queries/Get-MtLdapForest.ps1
  • powershell/internal/services/ad/queries/Get-MtLdapOptionalFeature.ps1
  • powershell/internal/services/ad/queries/Get-MtLdapPrinter.ps1
  • powershell/internal/services/ad/queries/Get-MtLdapReplicationSite.ps1
  • powershell/internal/services/ad/queries/Get-MtLdapSchemaObject.ps1
  • powershell/internal/services/ad/queries/Get-MtLdapServiceAccount.ps1
  • powershell/internal/services/ad/queries/Get-MtLdapUser.ps1
  • powershell/internal/services/ad/transport/Get-MtSysvolContent.ps1
  • powershell/public/services/ad/Get-MtADDomainState.ps1
  • powershell/public/services/ad/Get-MtADGpoState.ps1
  • powershell/tests/ad/transport/Get-MtSysvolContent.Tests.ps1
  • powershell/tests/functions/ADCertificateInventoryBatch.Tests.ps1
  • powershell/tests/functions/ADCollectorQueries.Tests.ps1
  • powershell/tests/functions/ADComputerChecks.Tests.ps1
  • powershell/tests/functions/ADConfigurationChecks.Tests.ps1
  • powershell/tests/functions/ADDaclConsolidation.Tests.ps1
  • powershell/tests/functions/ADDomainForestBatch.Tests.ps1
  • powershell/tests/functions/ADGpoInventory.Tests.ps1
  • powershell/tests/functions/ADGpoReports.Tests.ps1
  • powershell/tests/functions/ADGroupSpnChecks.Tests.ps1
  • powershell/tests/functions/ADGuideContent.Tests.ps1
  • powershell/tests/functions/ADPasswordPolicyBatch.Tests.ps1
  • powershell/tests/functions/ADResultPresentation.Tests.ps1
  • powershell/tests/functions/ADReviewCorrections.Tests.ps1
  • powershell/tests/functions/ADSchemaTrustChecks.Tests.ps1
  • powershell/tests/functions/ADSecondBatchCollectors.Tests.ps1
  • powershell/tests/functions/ADSiteOuBatch.Tests.ps1
  • powershell/tests/functions/ADUserSecurityBatch.Tests.ps1
  • powershell/tests/functions/ActiveDirectoryDacl.Tests.ps1
  • powershell/tests/functions/ActiveDirectoryGpoPermissions.Tests.ps1
  • powershell/tests/functions/ActiveDirectoryIssues.Tests.ps1
  • powershell/tests/functions/ActiveDirectoryOptIn.Tests.ps1
  • powershell/tests/functions/AdNtAuthCertificatePath.Tests.ps1
  • powershell/tests/functions/engine/Frameworks.Tests.ps1
  • powershell/tests/functions/golden/Golden.Tests.ps1
  • tests/ad/certificate-services/Test.AD-PKI-13.md
  • tests/ad/certificate-services/Test.AD-PKI-13.ps1
  • tests/ad/computer/Test.AD-COMP-01.md
  • tests/ad/computer/Test.AD-COMP-01.ps1
  • tests/ad/computer/Test.AD-COMP-02.md
  • tests/ad/computer/Test.AD-COMP-02.ps1
  • tests/ad/computer/Test.AD-COMP-03.md
  • tests/ad/computer/Test.AD-COMP-03.ps1
  • tests/ad/computer/Test.AD-COMP-04.md
  • tests/ad/computer/Test.AD-COMP-04.ps1
  • tests/ad/computer/Test.AD-COMP-05.md
  • tests/ad/computer/Test.AD-COMP-05.ps1
  • tests/ad/computer/Test.AD-COMP-06.md
  • tests/ad/computer/Test.AD-COMP-06.ps1
  • tests/ad/computer/Test.AD-COMP-07.md
  • tests/ad/computer/Test.AD-COMP-07.ps1
  • tests/ad/computer/Test.AD-COMP-08.md
  • tests/ad/computer/Test.AD-COMP-08.ps1
  • tests/ad/computer/Test.AD-COMP-09.md
  • tests/ad/computer/Test.AD-COMP-09.ps1
  • tests/ad/computer/Test.AD-COMP-10.md
  • tests/ad/computer/Test.AD-COMP-10.ps1
  • tests/ad/config/Test.AD-CFG-01.md
  • tests/ad/config/Test.AD-CFG-01.ps1
  • tests/ad/config/Test.AD-CFG-02.md
  • tests/ad/config/Test.AD-CFG-02.ps1
  • tests/ad/config/Test.AD-CFG-03.md
  • tests/ad/config/Test.AD-CFG-03.ps1
  • tests/ad/config/Test.AD-CFG-04.md
  • tests/ad/config/Test.AD-CFG-04.ps1
  • tests/ad/config/Test.AD-CFG-05.md
  • tests/ad/config/Test.AD-CFG-05.ps1
  • tests/ad/config/Test.AD-CFG-06.md
  • tests/ad/config/Test.AD-CFG-06.ps1
  • tests/ad/config/Test.AD-CFG-07.md
  • tests/ad/config/Test.AD-CFG-07.ps1
  • tests/ad/config/Test.AD-CFG-08.md
  • tests/ad/config/Test.AD-CFG-08.ps1
  • tests/ad/config/Test.AD-CFG-09.md
  • tests/ad/config/Test.AD-CFG-09.ps1
  • tests/ad/config/Test.AD-CFG-10.md
  • tests/ad/config/Test.AD-CFG-10.ps1
  • tests/ad/config/Test.AD-CFG-11.md
  • tests/ad/config/Test.AD-CFG-11.ps1
  • tests/ad/config/Test.AD-CFG-12.md
  • tests/ad/config/Test.AD-CFG-12.ps1
  • tests/ad/config/Test.AD-CFG-13.md
  • tests/ad/config/Test.AD-CFG-13.ps1
  • tests/ad/config/Test.AD-CFG-14.md
  • tests/ad/config/Test.AD-CFG-14.ps1
  • tests/ad/config/Test.AD-CFG-15.md
  • tests/ad/config/Test.AD-CFG-15.ps1
  • tests/ad/config/Test.AD-CFG-16.md
  • tests/ad/config/Test.AD-CFG-16.ps1
  • tests/ad/config/Test.AD-CFG-17.md
  • tests/ad/config/Test.AD-CFG-17.ps1
  • tests/ad/config/Test.AD-CFG-18.md
  • tests/ad/config/Test.AD-CFG-18.ps1
  • tests/ad/config/Test.AD-CFG-19.md
  • tests/ad/config/Test.AD-CFG-19.ps1
  • tests/ad/config/Test.AD-CFG-20.md
  • tests/ad/config/Test.AD-CFG-20.ps1
  • tests/ad/config/Test.AD-CFG-21.md
  • tests/ad/config/Test.AD-CFG-21.ps1
  • tests/ad/config/Test.AD-CFG-22.md
  • tests/ad/config/Test.AD-CFG-22.ps1
  • tests/ad/config/Test.AD-CFG-23.md
  • tests/ad/config/Test.AD-CFG-23.ps1
  • tests/ad/config/Test.AD-CFG-24.md
  • tests/ad/config/Test.AD-CFG-24.ps1
  • tests/ad/dacl/Test.AD-DACL-01.md
  • tests/ad/dacl/Test.AD-DACL-02.md
  • tests/ad/dacl/Test.AD-DACL-03.md
  • tests/ad/dacl/Test.AD-DACL-03.ps1
  • tests/ad/dacl/Test.AD-DACL-04.md
  • tests/ad/dacl/Test.AD-DACL-04.ps1
  • tests/ad/dacl/Test.AD-DACL-05.md
  • tests/ad/dacl/Test.AD-DACL-05.ps1
  • tests/ad/dacl/Test.AD-DACL-06.md
  • tests/ad/dacl/Test.AD-DACL-06.ps1
  • tests/ad/dacl/Test.AD-DACL-07.md
  • tests/ad/dacl/Test.AD-DACL-07.ps1
  • tests/ad/dacl/Test.AD-DACL-08.md
  • tests/ad/dacl/Test.AD-DACL-08.ps1
  • tests/ad/dacl/Test.AD-DACL-09.md
  • tests/ad/dacl/Test.AD-DACL-09.ps1
  • tests/ad/dacl/Test.AD-DACL-10.md
  • tests/ad/dacl/Test.AD-DACL-10.ps1
  • tests/ad/dacl/Test.AD-DACL-11.md
  • tests/ad/dacl/Test.AD-DACL-11.ps1
  • tests/ad/dacl/Test.AD-DACL-12.md
  • tests/ad/dacl/Test.AD-DACL-12.ps1
  • tests/ad/dacl/Test.AD-DACL-13.md
  • tests/ad/dacl/Test.AD-DACL-13.ps1
  • tests/ad/dacl/Test.AD-DACL-14.md
  • tests/ad/dacl/Test.AD-DACL-15.md
  • tests/ad/dacl/Test.AD-DACL-15.ps1
  • tests/ad/dacl/Test.AD-DACL-16.md
  • tests/ad/dacl/Test.AD-DACL-16.ps1
  • tests/ad/dacl/Test.AD-DACL-17.md
  • tests/ad/dacl/Test.AD-DACL-17.ps1
  • tests/ad/dacl/Test.AD-DACL-18.md
  • tests/ad/dacl/Test.AD-DACL-18.ps1
  • tests/ad/delegation/Test.AD-USER-05.md
  • tests/ad/delegation/Test.AD-USER-05.ps1
  • tests/ad/dns/Test.AD-DNS-01.md
  • tests/ad/dns/Test.AD-DNS-02.md
  • tests/ad/dns/Test.AD-DNS-03.md
  • tests/ad/dns/Test.AD-DNS-04.md
  • tests/ad/dns/Test.AD-DNS-05.md
  • tests/ad/dns/Test.AD-DNS-06.md
  • tests/ad/dns/Test.AD-DNS-07.md
  • tests/ad/dns/Test.AD-DNS-08.md
  • tests/ad/dns/Test.AD-DNS-09.md
  • tests/ad/dns/Test.AD-DNS-10.md
  • tests/ad/dns/Test.AD-DNS-11.md
  • tests/ad/dns/Test.AD-DNS-12.md
  • tests/ad/dns/Test.AD-DNS-14.md
  • tests/ad/dns/Test.AD-DNS-16.md
  • tests/ad/dns/Test.AD-DNS-18.md
  • tests/ad/dns/Test.AD-DNS-19.md
  • tests/ad/domain-controller/Test.AD-DC-01.md
  • tests/ad/domain-controller/Test.AD-DC-01.ps1
  • tests/ad/domain-controller/Test.AD-DC-02.md
  • tests/ad/domain-controller/Test.AD-DC-03.md
  • tests/ad/domain-controller/Test.AD-DC-04.md
  • tests/ad/domain-controller/Test.AD-DC-05.md
  • tests/ad/domain-controller/Test.AD-DC-05.ps1
  • tests/ad/domain-controller/Test.AD-DC-06.md
  • tests/ad/domain-controller/Test.AD-DC-06.ps1
  • tests/ad/domain-controller/Test.AD-DC-07.md
  • tests/ad/domain-controller/Test.AD-DC-07.ps1
  • tests/ad/domain-controller/Test.AD-DC-08.md
  • tests/ad/domain-controller/Test.AD-DC-08.ps1
  • tests/ad/domain-controller/Test.AD-DCD-01.md
  • tests/ad/domain-controller/Test.AD-DCD-01.ps1
  • tests/ad/domain-controller/Test.AD-DCD-02.md
  • tests/ad/domain-controller/Test.AD-DCD-02.ps1
  • tests/ad/domain-controller/Test.AD-DCD-03.md
  • tests/ad/domain-controller/Test.AD-DCD-03.ps1
  • tests/ad/domain-controller/Test.AD-DCD-04.md
  • tests/ad/domain-controller/Test.AD-DCD-04.ps1
  • tests/ad/domain/Test.AD-DOM-01.md
  • tests/ad/domain/Test.AD-DOM-01.ps1
  • tests/ad/domain/Test.AD-DOM-02.md
  • tests/ad/domain/Test.AD-DOM-02.ps1
  • tests/ad/domain/Test.AD-DOM-03.md
  • tests/ad/domain/Test.AD-DOM-03.ps1
  • tests/ad/domain/Test.AD-DOM-04.md
  • tests/ad/domain/Test.AD-DOM-04.ps1
  • tests/ad/domain/Test.AD-DOM-05.md
  • tests/ad/domain/Test.AD-DOM-05.ps1
  • tests/ad/domain/Test.AD-DOM-06.md
  • tests/ad/domain/Test.AD-DOM-06.ps1
  • tests/ad/domain/Test.AD-DOM-07.md
  • tests/ad/domain/Test.AD-DOM-07.ps1
  • tests/ad/domain/Test.AD-DOM-08.md
  • tests/ad/domain/Test.AD-DOM-08.ps1
  • tests/ad/domain/Test.AD-DOMS-01.md
  • tests/ad/domain/Test.AD-DOMS-01.ps1
  • tests/ad/domain/Test.AD-FOR-01.md
  • tests/ad/domain/Test.AD-FOR-01.ps1
  • tests/ad/domain/Test.AD-FOR-02.md
  • tests/ad/domain/Test.AD-FOR-02.ps1
  • tests/ad/domain/Test.AD-FOR-03.md
  • tests/ad/domain/Test.AD-FOR-03.ps1
  • tests/ad/domain/Test.AD-FOR-04.md
  • tests/ad/domain/Test.AD-FOR-04.ps1
  • tests/ad/domain/Test.AD-FORS-01.md
  • tests/ad/domain/Test.AD-FORS-01.ps1
  • tests/ad/domain/Test.AD-FORS-02.md
  • tests/ad/domain/Test.AD-FORS-02.ps1
  • tests/ad/domain/Test.AD-FORS-03.md
  • tests/ad/domain/Test.AD-FORS-03.ps1
  • tests/ad/domain/Test.AD-FORS-04.md
  • tests/ad/domain/Test.AD-FORS-04.ps1
  • tests/ad/gpo-state/Test.AD-GPOREP-01.md
  • tests/ad/gpo-state/Test.AD-GPOREP-01.ps1
  • tests/ad/gpo-state/Test.AD-GPOREP-02.md
  • tests/ad/gpo-state/Test.AD-GPOREP-02.ps1
  • tests/ad/gpo-state/Test.AD-GPOREP-03.md
  • tests/ad/gpo-state/Test.AD-GPOREP-03.ps1
  • tests/ad/gpo-state/Test.AD-GPOREP-04.md
  • tests/ad/gpo-state/Test.AD-GPOREP-04.ps1
  • tests/ad/gpo-state/Test.AD-GPOREP-05.md
  • tests/ad/gpo-state/Test.AD-GPOREP-06.md
  • tests/ad/gpo-state/Test.AD-GPOREP-07.md
  • tests/ad/gpo-state/Test.AD-GPOREP-07.ps1
  • tests/ad/gpo-state/Test.AD-GPOREP-08.md
  • tests/ad/gpo-state/Test.AD-GPOREP-08.ps1
  • tests/ad/gpo-state/Test.AD-GPOREP-09.md
  • tests/ad/gpo-state/Test.AD-GPOREP-10.md
  • tests/ad/gpo-state/Test.AD-GPOREP-10.ps1
  • tests/ad/gpo-state/Test.AD-GPOREP-11.md
  • tests/ad/gpo-state/Test.AD-GPOREP-11.ps1
  • tests/ad/gpo-state/Test.AD-GPOREP-12.md
  • tests/ad/gpo-state/Test.AD-GPOREP-12.ps1
  • tests/ad/gpo-state/Test.AD-GPOREP-13.md
  • tests/ad/gpo-state/Test.AD-GPOREP-13.ps1
  • tests/ad/gpo-state/Test.AD-GPOREP-14.md
  • tests/ad/gpo-state/Test.AD-GPOREP-15.md
  • tests/ad/gpo-state/Test.AD-GPOREP-15.ps1
  • tests/ad/gpo-state/Test.AD-GPOREP-16.md
  • tests/ad/gpo-state/Test.AD-GPOREP-16.ps1
  • tests/ad/gpo-state/Test.AD-GPOREP-17.md
  • tests/ad/gpo-state/Test.AD-GPOREP-17.ps1
  • tests/ad/gpo-state/Test.AD-GPOREP-18.md
  • tests/ad/gpo-state/Test.AD-GPOREP-18.ps1
  • tests/ad/gpo-state/Test.AD-GPOREP-19.md
  • tests/ad/gpo-state/Test.AD-GPOREP-19.ps1
  • tests/ad/gpo-state/Test.AD-GPOREP-20.md
  • tests/ad/gpo-state/Test.AD-GPOREP-20.ps1
  • tests/ad/gpo-state/Test.AD-GPOS-01.md
  • tests/ad/gpo-state/Test.AD-GPOS-02.md
  • tests/ad/gpo-state/Test.AD-GPOS-03.md
  • tests/ad/gpo-state/Test.AD-GPOS-04.md
  • tests/ad/gpo-state/Test.AD-GPOS-05.md
  • tests/ad/gpo-state/Test.AD-GPOS-06.md
  • tests/ad/gpo-state/Test.AD-GPOS-07.md
  • tests/ad/gpo-state/Test.AD-GPOS-08.md
  • tests/ad/gpo-state/Test.AD-GPOS-09.md
  • tests/ad/gpo/Test.AD-GPO-01.md
  • tests/ad/gpo/Test.AD-GPO-01.ps1
  • tests/ad/gpo/Test.AD-GPO-02.md
  • tests/ad/gpo/Test.AD-GPO-02.ps1
  • tests/ad/gpo/Test.AD-GPO-03.md
  • tests/ad/gpo/Test.AD-GPO-03.ps1
  • tests/ad/gpo/Test.AD-GPO-04.md
  • tests/ad/gpo/Test.AD-GPO-04.ps1
  • tests/ad/gpo/Test.AD-GPO-05.md
  • tests/ad/gpo/Test.AD-GPO-05.ps1
  • tests/ad/gpo/Test.AD-GPOL-01.md
  • tests/ad/gpo/Test.AD-GPOL-02.md
  • tests/ad/gpo/Test.AD-GPOL-02.ps1
  • tests/ad/gpo/Test.AD-GPOL-03.md
  • tests/ad/gpo/Test.AD-GPOL-03.ps1
  • tests/ad/gpo/Test.AD-GPOL-04.md
  • tests/ad/gpo/Test.AD-GPOL-04.ps1
  • tests/ad/gpo/Test.AD-GPOL-05.md
  • tests/ad/gpo/Test.AD-GPOL-05.ps1
  • tests/ad/gpo/Test.AD-GPOL-06.md
  • tests/ad/gpo/Test.AD-GPOL-06.ps1
  • tests/ad/group/Test.AD-GCHG-01.md
  • tests/ad/group/Test.AD-GMC-01.md
  • tests/ad/group/Test.AD-GMC-01.ps1
  • tests/ad/group/Test.AD-GMC-02.md
  • tests/ad/group/Test.AD-GMC-02.ps1
  • tests/ad/group/Test.AD-GMC-03.md
  • tests/ad/group/Test.AD-GMC-03.ps1
  • tests/ad/group/Test.AD-GMC-04.md
  • tests/ad/group/Test.AD-GMC-04.ps1
  • tests/ad/group/Test.AD-GMC-05.md
  • tests/ad/group/Test.AD-GMC-05.ps1
  • tests/ad/group/Test.AD-GMC-06.md
  • tests/ad/group/Test.AD-GMC-06.ps1
  • tests/ad/group/Test.AD-GMC-07.md
  • tests/ad/group/Test.AD-GMC-07.ps1
  • tests/ad/group/Test.AD-GMC-08.md
  • tests/ad/group/Test.AD-GMC-08.ps1
  • tests/ad/group/Test.AD-GMC-09.md
  • tests/ad/group/Test.AD-GMC-09.ps1
  • tests/ad/group/Test.AD-GMC-10.md
  • tests/ad/group/Test.AD-GMC-10.ps1
  • tests/ad/group/Test.AD-GMC-11.md
  • tests/ad/group/Test.AD-GMC-11.ps1
  • tests/ad/group/Test.AD-GRP-01.md
  • tests/ad/group/Test.AD-GRP-01.ps1
  • tests/ad/group/Test.AD-GRP-02.md
  • tests/ad/group/Test.AD-GRP-02.ps1
  • tests/ad/group/Test.AD-GRP-03.md
  • tests/ad/group/Test.AD-GRP-03.ps1
  • tests/ad/group/Test.AD-GRP-04.md
  • tests/ad/group/Test.AD-GRP-04.ps1
  • tests/ad/group/Test.AD-GRP-05.md
  • tests/ad/group/Test.AD-GRP-05.ps1
  • tests/ad/group/Test.AD-GRP-06.md
  • tests/ad/group/Test.AD-GRP-06.ps1
  • tests/ad/group/Test.AD-GRP-07.md
  • tests/ad/group/Test.AD-GRP-07.ps1
  • tests/ad/group/Test.AD-GRP-08.md
  • tests/ad/group/Test.AD-GRP-08.ps1
  • tests/ad/group/Test.AD-GRP-09.md
  • tests/ad/group/Test.AD-GRP-09.ps1
  • tests/ad/group/Test.AD-GRP-10.md
  • tests/ad/group/Test.AD-GRP-10.ps1
  • tests/ad/ou/Test.AD-OU-01.md
  • tests/ad/ou/Test.AD-OU-01.ps1
  • tests/ad/ou/Test.AD-OU-02.md
  • tests/ad/ou/Test.AD-OU-02.ps1
  • tests/ad/ou/Test.AD-OU-03.md
  • tests/ad/ou/Test.AD-OU-03.ps1
  • tests/ad/ou/Test.AD-OU-04.md
  • tests/ad/ou/Test.AD-OU-04.ps1
  • tests/ad/ou/Test.AD-OU-05.md
  • tests/ad/ou/Test.AD-OU-05.ps1
  • tests/ad/password-policy/Test.AD-FGPP-01.md
  • tests/ad/password-policy/Test.AD-FGPP-01.ps1
  • tests/ad/password-policy/Test.AD-FGPP-02.md
  • tests/ad/password-policy/Test.AD-FGPP-02.ps1
  • tests/ad/password-policy/Test.AD-FGPP-03.md
  • tests/ad/password-policy/Test.AD-FGPP-03.ps1
  • tests/ad/password-policy/Test.AD-FGPP-04.md
  • tests/ad/password-policy/Test.AD-FGPP-04.ps1
  • tests/ad/password-policy/Test.AD-PWDPOL-01.md
  • tests/ad/password-policy/Test.AD-PWDPOL-01.ps1
  • tests/ad/password-policy/Test.AD-PWDPOL-02.md
  • tests/ad/password-policy/Test.AD-PWDPOL-02.ps1
  • tests/ad/password-policy/Test.AD-PWDPOL-03.md
  • tests/ad/password-policy/Test.AD-PWDPOL-03.ps1
  • tests/ad/password-policy/Test.AD-PWDPOL-04.md
  • tests/ad/password-policy/Test.AD-PWDPOL-04.ps1
  • tests/ad/password-policy/Test.AD-PWDPOL-05.md
  • tests/ad/password-policy/Test.AD-PWDPOL-05.ps1
  • tests/ad/password-policy/Test.AD-PWDPOL-06.md
  • tests/ad/password-policy/Test.AD-PWDPOL-06.ps1
  • tests/ad/password-policy/Test.AD-PWDPOL-07.md
  • tests/ad/password-policy/Test.AD-PWDPOL-07.ps1
  • tests/ad/printer/Test.AD-PRINT-01.md
  • tests/ad/printer/Test.AD-PRINT-01.ps1
  • tests/ad/replication/Test.AD-DFSR-01.md
  • tests/ad/replication/Test.AD-FEAT-01.md
  • tests/ad/replication/Test.AD-FEAT-01.ps1
  • tests/ad/replication/Test.AD-FEAT-02.md
  • tests/ad/replication/Test.AD-FEAT-02.ps1
  • tests/ad/replication/Test.AD-REPL-01.md
  • tests/ad/replication/Test.AD-REPL-02.md
  • tests/ad/replication/Test.AD-ROOTDSE-01.md
  • tests/ad/replication/Test.AD-ROOTDSE-01.ps1
  • tests/ad/replication/Test.AD-ROOTDSE-02.md
  • tests/ad/replication/Test.AD-ROOTDSE-02.ps1
  • tests/ad/replication/Test.AD-ROOTDSE-03.md
  • tests/ad/schema/Test.AD-SCH-01.md
  • tests/ad/schema/Test.AD-SCH-01.ps1
  • tests/ad/schema/Test.AD-SCH-02.md
  • tests/ad/schema/Test.AD-SCH-02.ps1
  • tests/ad/schema/Test.AD-SCH-03.md
  • tests/ad/schema/Test.AD-SCH-03.ps1
  • tests/ad/schema/Test.AD-SCH-04.md
  • tests/ad/schema/Test.AD-SCH-04.ps1
  • tests/ad/schema/Test.AD-SCH-05.md
  • tests/ad/schema/Test.AD-SCH-05.ps1
  • tests/ad/security/Test.AD-DCOMP-01.md
  • tests/ad/security/Test.AD-DCOMP-01.ps1
  • tests/ad/security/Test.AD-DCOMP-02.md
  • tests/ad/security/Test.AD-DCOMP-02.ps1
  • tests/ad/security/Test.AD-DCOMP-03.md
  • tests/ad/security/Test.AD-DCOMP-03.ps1
  • tests/ad/security/Test.AD-DCOMP-04.md
  • tests/ad/security/Test.AD-DCOMP-04.ps1
  • tests/ad/security/Test.AD-DCOMP-05.md
  • tests/ad/security/Test.AD-DCOMP-05.ps1
  • tests/ad/security/Test.AD-DCOMP-06.md
  • tests/ad/security/Test.AD-DCOMP-06.ps1
  • tests/ad/security/Test.AD-DCOMP-07.md
  • tests/ad/security/Test.AD-DCOMP-07.ps1
  • tests/ad/security/Test.AD-DCOMP-08.md
  • tests/ad/security/Test.AD-DCOMP-08.ps1
  • tests/ad/security/Test.AD-DCOMP-09.md
  • tests/ad/security/Test.AD-DCOMP-09.ps1
  • tests/ad/security/Test.AD-KRBTGT-01.md
  • tests/ad/security/Test.AD-KRBTGT-01.ps1
  • tests/ad/security/Test.AD-KRBTGT-02.md
  • tests/ad/security/Test.AD-KRBTGT-03.md
  • tests/ad/security/Test.AD-MSA-01.md
  • tests/ad/security/Test.AD-MSA-01.ps1
  • tests/ad/site/Test.AD-SITE-01.md
  • tests/ad/site/Test.AD-SITE-01.ps1
  • tests/ad/site/Test.AD-SITE-02.md
  • tests/ad/site/Test.AD-SITE-02.ps1
  • tests/ad/site/Test.AD-SITE-03.md
  • tests/ad/site/Test.AD-SITE-03.ps1
  • tests/ad/site/Test.AD-SITE-04.md
  • tests/ad/site/Test.AD-SITE-04.ps1
  • tests/ad/site/Test.AD-SITE-05.md
  • tests/ad/site/Test.AD-SITE-05.ps1
  • tests/ad/site/Test.AD-SUB-01.md
  • tests/ad/site/Test.AD-SUB-01.ps1
  • tests/ad/site/Test.AD-SUB-02.md
  • tests/ad/site/Test.AD-SUB-02.ps1
  • tests/ad/site/Test.AD-SUB-03.md
  • tests/ad/site/Test.AD-SUB-03.ps1
  • tests/ad/site/Test.AD-SUB-04.md
  • tests/ad/site/Test.AD-SUB-04.ps1
  • tests/ad/site/Test.AD-SUB-05.md
  • tests/ad/site/Test.AD-SUB-05.ps1
  • tests/ad/site/Test.AD-SUB-06.md
  • tests/ad/site/Test.AD-SUB-06.ps1
  • tests/ad/site/Test.AD-SUB-07.md
  • tests/ad/site/Test.AD-SUB-07.ps1
  • tests/ad/site/Test.AD-SUB-08.md
  • tests/ad/site/Test.AD-SUB-08.ps1
  • tests/ad/site/Test.AD-SUB-09.md
  • tests/ad/site/Test.AD-SUB-09.ps1
  • tests/ad/site/Test.AD-SUB-10.md
  • tests/ad/site/Test.AD-SUB-10.ps1
  • tests/ad/site/Test.AD-SUB-11.md
  • tests/ad/site/Test.AD-SUB-11.ps1
  • tests/ad/spn/Test.AD-SPN-01.md
  • tests/ad/spn/Test.AD-SPN-01.ps1
  • tests/ad/spn/Test.AD-SPN-02.md
  • tests/ad/spn/Test.AD-SPN-02.ps1
  • tests/ad/spn/Test.AD-SPN-03.md
  • tests/ad/spn/Test.AD-SPN-03.ps1
  • tests/ad/spn/Test.AD-SPN-04.md
  • tests/ad/spn/Test.AD-SPN-04.ps1
  • tests/ad/spn/Test.AD-SPN-05.md
  • tests/ad/spn/Test.AD-SPN-05.ps1
  • tests/ad/spn/Test.AD-SPN-06.md
  • tests/ad/spn/Test.AD-SPN-06.ps1
  • tests/ad/spn/Test.AD-SPN-07.md
  • tests/ad/spn/Test.AD-SPN-07.ps1
  • tests/ad/spn/Test.AD-SPN-08.md
  • tests/ad/spn/Test.AD-SPN-08.ps1
  • tests/ad/spn/Test.AD-SPN-09.md
  • tests/ad/spn/Test.AD-SPN-09.ps1
  • tests/ad/spn/Test.AD-SPN-10.md
  • tests/ad/spn/Test.AD-SPN-10.ps1
  • tests/ad/spn/Test.AD-SPN-11.md
  • tests/ad/spn/Test.AD-SPN-11.ps1
  • tests/ad/spn/Test.AD-SPN-12.md
  • tests/ad/spn/Test.AD-SPN-12.ps1
  • tests/ad/spn/Test.AD-SPN-13.md
  • tests/ad/spn/Test.AD-SPN-13.ps1
  • tests/ad/trust/Test.AD-TRUST-01.md
  • tests/ad/trust/Test.AD-TRUST-01.ps1
  • tests/ad/trust/Test.AD-TRUST-02.md
  • tests/ad/trust/Test.AD-TRUST-02.ps1
  • tests/ad/trust/Test.AD-TRUST-03.md
  • tests/ad/trust/Test.AD-TRUST-03.ps1
  • tests/ad/trust/Test.AD-TRUST-04.md
  • tests/ad/trust/Test.AD-TRUST-04.ps1
  • tests/ad/trust/Test.AD-TRUST-05.md
  • tests/ad/trust/Test.AD-TRUST-05.ps1
  • tests/ad/trust/Test.AD-TRUST-06.md
  • tests/ad/trust/Test.AD-TRUST-06.ps1
  • tests/ad/trust/Test.AD-TRUST-07.md
  • tests/ad/trust/Test.AD-TRUST-07.ps1
  • tests/ad/user/Test.AD-USER-01.md
  • tests/ad/user/Test.AD-USER-01.ps1
  • tests/ad/user/Test.AD-USER-02.md
  • tests/ad/user/Test.AD-USER-02.ps1
  • tests/ad/user/Test.AD-USER-03.md
  • tests/ad/user/Test.AD-USER-03.ps1
  • tests/ad/user/Test.AD-USER-04.md
  • tests/ad/user/Test.AD-USER-04.ps1
  • tests/ad/user/Test.AD-USER-05.md
  • tests/ad/user/Test.AD-USER-05.ps1
  • tests/ad/user/Test.AD-USER-06.md
  • tests/ad/user/Test.AD-USER-06.ps1
  • tests/ad/user/Test.AD-USER-07.md
  • tests/ad/user/Test.AD-USER-07.ps1
  • tests/ad/user/Test.AD-USER-08.md
  • tests/ad/user/Test.AD-USER-08.ps1
  • tests/ad/user/Test.AD-USER-09.md
  • tests/ad/user/Test.AD-USER-09.ps1
  • tests/ad/user/Test.AD-USER-10.md
  • tests/ad/user/Test.AD-USER-10.ps1
  • tests/ad/user/Test.AD-USER-11.md
  • tests/ad/user/Test.AD-USER-11.ps1
  • tests/ad/user/Test.AD-USER-12.md
  • tests/ad/user/Test.AD-USER-12.ps1
  • tests/ad/user/Test.AD-USER-13.md
  • tests/ad/user/Test.AD-USER-13.ps1
  • tests/ad/user/Test.AD-USER-14.md
  • tests/ad/user/Test.AD-USER-14.ps1
  • tests/ad/user/Test.AD-USER-15.md
  • tests/ad/user/Test.AD-USER-15.ps1
  • tests/ad/user/Test.AD-USER-16.md
  • tests/ad/user/Test.AD-USER-16.ps1
  • tests/ad/user/Test.AD-USER-17.md
  • tests/ad/user/Test.AD-USER-17.ps1
  • tests/ad/user/Test.AD-USER-18.md
  • tests/ad/user/Test.AD-USER-18.ps1
  • tests/ad/user/Test.AD-USER-19.md
  • tests/ad/user/Test.AD-USER-19.ps1
  • tests/ad/user/Test.AD-USER-20.md
  • tests/ad/user/Test.AD-USER-20.ps1
  • tests/ad/user/Test.AD-USER-21.md
  • tests/ad/user/Test.AD-USER-21.ps1
  • tests/ad/user/Test.AD-USER-22.md
  • tests/ad/user/Test.AD-USER-22.ps1
  • tests/ad/user/Test.AD-USER-23.md
  • tests/ad/user/Test.AD-USER-23.ps1
  • tests/ad/user/Test.AD-USER-24.md
  • tests/ad/user/Test.AD-USER-24.ps1
  • tests/ad/user/Test.AD-USER-25.md
  • tests/ad/user/Test.AD-USER-25.ps1
  • tests/ad/user/Test.AD-USER-26.md
  • tests/ad/user/Test.AD-USER-26.ps1
  • tests/ad/user/Test.AD-USER-27.md
  • tests/ad/user/Test.AD-USER-27.ps1
  • tests/ad/user/Test.AD-USER-28.md
  • tests/ad/user/Test.AD-USER-28.ps1
  • tests/ad/user/Test.AD-USER-29.md
  • tests/ad/user/Test.AD-USER-29.ps1
  • website/docs/advanced/active-directory.md
  • website/docs/upgrading-from-2x.md
  • website/scripts/test-retired-test-redirects.mjs
  • website/src/data/test-builder.json
  • website/src/lib/redirects.mjs

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

@github-actions

github-actions Bot commented Nov 14, 2026 •

Copy link
Copy Markdown
Contributor

Attribute review

Attribute review: 47 tests need review, more than the limit of 25 for one run. Split the change, or ask a maintainer to review the attributes and apply the attribute-review-override label.

@codacy-production

Copy link
Copy Markdown

Up to standards ✅

🟢 Issues 0 issues

Results:
0 new issues

View in Codacy

NEW Get contextual insights on your PRs based on Codacy's metrics, along with PR and Jira context, without leaving GitHub. Enable AI reviewer
TIP This summary will be updated as you push new changes.

@FiraSenax
FiraSenax marked this pull request as ready for review November 14, 2026 17:37
@FiraSenax
FiraSenax requested review from a team as code owners November 14, 2026 17:37
@FiraSenax FiraSenax mentioned this pull request Nov 15, 2026
5 of 7 tasks

@earbona23 earbona23 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The check itself reads well — CustomRootTrust with DisableCertificateDownloads, revocation explicitly off and recorded as off in the output, every X509Certificate2 and X509Chain disposed in a finally, and PathUsesCertificateOutsidePublishedInventory to catch a path that leans on something the inventory never published. Offline is the right call for this, and the result says plainly what it does not assess.

Two things before it can be read, though, and the first is why I started here rather than in the diff.

This pull request carries #2734

GitHub shows 567 files and -18,692 lines against main. Measured locally, almost none of that is yours:

git merge-base --is-ancestor <soulemike/ad-test-consolidation> <codex/ntauth-certificate-chain>
  -> true, so this branch contains #2734's commits

git diff --stat <soulemike/ad-test-consolidation> <codex/ntauth-certificate-chain>
  -> 5 files changed, 494 insertions(+), 2 deletions(-)

git rev-list --count <soulemike/ad-test-consolidation>..<codex/ntauth-certificate-chain>
  -> 3

Your own work is three commits over five files:

File
powershell/internal/services/ad/Get-MtAdNtAuthCertificatePath.ps1 +122
powershell/tests/functions/AdNtAuthCertificatePath.Tests.ps1 +281
tests/ad/certificate-services/Test.AD-PKI-13.ps1 +55
tests/ad/certificate-services/Test.AD-PKI-13.md +27
powershell/internal/checks/ad/ad/Get-MtAdCertificateInventory.ps1 +9/-2

The other 562 are @soulemike's AD test consolidation, still open as #2734. Both branches delete the same 182 files under tests/ad/, and all 182 are still present on main, so as it stands this pull request would take the consolidation in under a title about NTAuth paths, and whichever lands first makes the other conflict — which is already why this one shows CONFLICTING.

Rebasing those three commits onto current main would turn this into a five-file review, and it would stop the consolidation being merged twice or reviewed in the wrong thread. If the dependency is real and Get-MtAdCertificateInventory -IncludeRawData only exists after #2734, then retargeting the base at that branch says so explicitly instead of hiding it.

-SkippedCustomReason is dropped here

Test.AD-PKI-13.ps1:

Add-MtTestResultDetail -SkippedBecause NotApplicable -SkippedCustomReason 'The collected NTAuth store contains no CA certificates.'

Add-MtTestResultDetail only reads -SkippedCustomReason when -SkippedBecause is Custom (powershell/public/run/Add-MtTestResultDetail.ps1:123-127); every other value takes the else branch and overwrites the reason with Get-MtSkippedReason $SkippedBecause. So that sentence never reaches the operator and the report shows the generic not-applicable text. Nothing else in the repository combines those two — -SkippedBecause Custom appears in 207 places and that is the form that keeps the message.

-SkippedBecause Custom -SkippedCustomReason '...' is what you want, and the empty store deserves the specific wording: it is the difference between "this does not apply to you" and "the store I read was empty".

One question

There is no return after that skip. It does terminate — the helper throws a skip record under the native engine and calls Set-ItResult -Skipped under Pester — so I do not think it is live, but the block below it builds a table over an empty $paths and calls Add-MtTestResultDetail a second time, so a reader has to go and check the helper to know it is unreachable. An explicit return would make it local.

And on the subordinate-CA count: the loop increments after comparing, walking ChainElements from leaf to root, and your comment says this is deliberate because Build treats the target as an end entity. That is the kind of off-by-one that is right until it is not — is there a case in the 281 lines of tests with a three-level path and pathLenConstraint = 0 on the root, where the engine's own InvalidBasicConstraints and your counter should agree?

@soulemike soulemike added the product: ad On-premises Active Directory label Nov 18, 2026

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

product: ad On-premises Active Directory

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants